package com.qi.service.impl;

import com.qi.commom.Student;
import com.qi.mapper.StudentMapper;
import com.qi.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;

@Service
public class StudentServiceImpl implements StudentService {
    @Autowired
    private StudentMapper studentMapper;

    /**
     * 查询全部学生
     * @return
     */
    @Override
    public ArrayList<Student> selectStudent() {
        return studentMapper.selectStudent();
    }

    /**
     * 添加学生
     * @param student
     * @return
     */
    @Override
    public Integer insertStudent(Student student) {
        return studentMapper.insertStudent(student);
    }
}
